package com.zryc.shop.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@ApiModel("商品实体")
@TableName("t_product")
@Data
@NoArgsConstructor
@AllArgsConstructor
public class Product {

    @ApiModelProperty(value = "主键")
    @TableId(type = IdType.AUTO)
    private Integer pid;            //主键

    @ApiModelProperty(value = "商品名称")
    private String pname;           //商品名称

    @ApiModelProperty(value = "商品单价")
    private Double pprice;          //商品单价

    @ApiModelProperty(value = "库存")
    private Integer stock;          //库存
}
